@keyframes chat {
  0% { opacity: 0 }
  100% { opacity: 1 }
}

.chat {
  display: flex;
  width: 200vh;
  height: 92vh;
  margin: 0;
  padding: 32px;
  background-image: linear-gradient(to right, #5FC3E4 0%, #E55D87 100%);
  animation: chat 1s;
}

.chat .list-pane {
  position: relative;
  width: calc(20% - 48px);
  height: calc(100% - 32px);
  background-color: white;
  border-radius: 16px;
  margin-right: 16px;
  padding: 16px;
}

.chat .list-pane .user-count {
  width: 100%;
  height: 64px;
  border-bottom: 2px solid;
  border-image: linear-gradient(to right, #5FC3E4 0%, #E55D87 100%) 2 2 2 2;
  margin-bottom: 16px;
}

.chat .list-pane .user-pane {
  width: 100%;
  height: calc(100% - 40px);
}

.chat .list-pane .user-pane .user-list {
  display: flex;
  flex-direction: column;
  position: relative;
  width: 100%;
  height: calc(100% - 64px);
  overflow: auto;
}

.chat .list-pane .user-pane .user-list .user {
  display: flex;
  align-items: center;
  margin-bottom: 16px;
}

.chat .list-pane .user-pane .user-list .user .user-img {
  width: 48px;
  height: 48px;
  border: pink solid 2px;
  border-radius: 64px;
}

.chat .list-pane .user-pane .user-list .user .username {
  font-size: 14px;
  margin: 0 0 0 16px;
  padding: 0;
}

.chat .list-pane .user-pane .user-list::-webkit-scrollbar {
  width: 8px;
  border-right: 8px;
}

.chat .list-pane .user-pane .user-list::-webkit-scrollbar-thumb {
  border-radius: 8px;
  background: #E55D87;
}

.chat .list-pane .user-pane .user-list::-webkit-scrollbar-track {
  border-radius: 8px;
  background: #f0f0f0;
}

.chat .chat-pane {
  display: flex;
  flex-direction: column;
  width: calc(80% - 80px);
  height: calc(100% - 64px);
  background-color: white;
  border-radius: 16px;
  margin-left: 16px;
  padding: 32px;
}

.chat .chat-pane .chat-header {
  display: flex;
  align-items: center;
  width: calc(100% - 16px);
  height: 5%;
  padding-left: 16px;
  text-align: left;
  border-bottom: 2px solid gray;
  margin-bottom: 16px;
}

.chat .chat-pane .chat-header h2 {
  padding: 0;
  margin: 0;
}

.chat .chat-pane .chat-message {
  width: calc(100%);
  height: 80%;
  border-top-left-radius: 4px;
  border-top-right-radius: 4px;
  background-color: #f5f6f7;
  border: 1px solid #DCDFE6;
  border-bottom: 0;
  padding: 16px;
  overflow: auto;
}

.chat .chat-pane .chat-message .user-message {
  display: flex;
  width: 100%;
  height: auto;
  margin-bottom: 16px;
}

.chat .chat-pane .chat-message .user-message .img {
  width: 64px;
  height: 64px;
  margin-right: 16px;
}

.chat .chat-pane .chat-message .user-message .img .user-img {
  width: 64px;
  height: 64px;
  margin-right: 16px;
  border: 2px solid white;
  border-radius: 8px;
}

.chat .chat-pane .chat-message .user-message .message {
  position: relative;
}

.chat .chat-pane .chat-message .user-message .message .username {
  text-align: left;
  margin-bottom: 8px;
  height: 24px;
}

.chat .chat-pane .chat-message .user-message .message .username .time {
  padding-left: 16px;
  color: gray;
}

.chat .chat-pane .chat-message .user-message .message .text {
  float: left;
  text-align: left;
  color: white;
  background-color: #1E6EFF;
  padding: 8px 16px;
  border-radius: 0 4px 4px 4px;
}

.chat .chat-pane .chat-message .user-message .message .text::selection {
  background: #3399FF;
}

.chat .chat-pane .chat-message .user-message .message .text::before {
  content: '';
  position: absolute;
  top: 32px;
  left: -4px;
  border-top: 2px solid #1E6EFF;
  border-right: 2px solid #1E6EFF;
  border-bottom: 2px solid transparent;
  border-left: 2px solid transparent;
}

.chat .chat-pane .chat-message .user-message .message .user-text {
  color: black;
  background-color: white;
}

.chat .chat-pane .chat-message .user-message .message .user-text::selection {
  color: white;
}

.chat .chat-pane .chat-message .user-message .message .user-text::before {
  border-top: 2px solid white;
  border-right: 2px solid white;
}

.chat .chat-pane .chat-textarea {
  display: flex;
  align-items: center;
  width: 100%;
  height: 15%;
  border-bottom-left-radius: 4px;
  border-bottom-right-radius: 4px;
  background-color: #f5f6f7;
  padding: 10px;
  box-sizing: border-box;
}
.me{
  float: right;

}
.chat .chat-pane .chat-textarea .user-textarea {
  flex-grow: 1;
  margin-right: 10px;
}

.chat .chat-pane .chat-textarea .user-textarea .el-textarea__inner {
  height: 100%; /* 确保输入框高度与父容器一致 */
  resize: none;
  box-sizing: border-box;
}

.chat .chat-pane .chat-textarea .send-button {
  height: 100%; /* 确保按钮高度与父容器一致 */
  box-sizing: border-box;
}

.chat .chat-pane .chat-message::-webkit-scrollbar,
.chat .chat-pane .chat-textarea .el-textarea__inner::-webkit-scrollbar {
  width: 6px;
  border-right: 8px;
}

.chat .chat-pane .chat-message::-webkit-scrollbar-thumb,
.chat .chat-pane .chat-textarea .el-textarea__inner::-webkit-scrollbar-thumb {
  border-radius: 8px;
  background: #4b8aff;
}

.chat .chat-pane .chat-message::-webkit-scrollbar-track,
.chat .chat-pane .chat-textarea .el-textarea__inner::-webkit-scrollbar-track {
  border-radius: 8px;
  background: #f0f0f0;
}
